import { hospital, smarthome, devices, video } from "@/utils/request.js" // 正确导入命名导出的变量

// 患者信息汇总
export const postdatacenterDbapi = (data) =>
  hospital.post(`/datacenter/dbapi`, data)

// 查询功能状态
export const postqueryStatusDbapi = (data) =>
  smarthome.post(`/znjj/oapi/devices/queryStatus`, data)

// // 查询紫外消毒累加时长
// export const postuvlampApi = (data) =>
//   smarthome.post(`/znjj/oapi/uvlamp`, data)


// 查询紫外定时任务
export const postschedulesApi = (data) =>
  smarthome.post(`/znjj/oapi/uvlamp/schedules`, data)

// 查询药柜全部药品列表
export const postygdatajApi = (id) =>
  devices.get(`/ygj/data?deviceId=${id}`)

// 查询药柜缺货
export const postygoutofstockjApi = (id) =>
  devices.get(`/ygj/outofstock?deviceId=${id}`)

// 查询药柜临期
export const postygjnearApi = (id) =>
  devices.get(`/ygj/near?deviceId=${id}`)

// 门禁信息列表
export const postDatacenterdbapiDbapi = (data) =>
  hospital.post(`/datacenter/dbapi`, data)

// 创建紫外定时任务
export const postscheduleAddapi = (data) =>
  smarthome.post(`/znjj/oapi/uvlamp/scheduleAdd`, data)


// 下发紫外定时任务
export const postschedulesissueapi = (data) =>
  smarthome.post(`/znjj/oapi/uvlamp/schedules/issue`, data)

// 立即关闭灯
export const postControlapi = (data) =>
  smarthome.post(`/znjj/oapi/devices/control`, data)


// 获取设备详情
export const postdevicesshowapi = (data) =>
  smarthome.post(`/znjj/oapi/devices/show`, data)


// 贴管机任务任务列表,自助机信息列表,机器人
export const postdatacenterdbapiapi = (data) =>
  hospital.post(`/datacenter/dbapi`, data)


// 贴管机状态
export const postgjstatusapi = (id) =>
  devices.get(`/tgj/status?ip=${id}`)
